3.144 \(\int \frac{(a+b \tan ^{-1}(c x))^2}{d+e x} \, dx\)

Optimal. Leaf size=223 \[ -\frac{i b \left (a+b \tan ^{-1}(c x)\right ) \text{PolyLog}\left (2,1-\frac{2 c (d+e x)}{(1-i c x) (c d+i e)}\right )}{e}+\frac{i b \text{PolyLog}\left (2,1-\frac{2}{1-i c x}\right ) \left (a+b \tan ^{-1}(c x)\right )}{e}+\frac{b^2 \text{PolyLog}\left (3,1-\frac{2 c (d+e x)}{(1-i c x) (c d+i e)}\right )}{2 e}-\frac{b^2 \text{PolyLog}\left (3,1-\frac{2}{1-i c x}\right )}{2 e}+\frac{\left (a+b \tan ^{-1}(c x)\right )^2 \log \left (\frac{2 c (d+e x)}{(1-i c x) (c d+i e)}\right )}{e}-\frac{\log \left (\frac{2}{1-i c x}\right ) \left (a+b \tan ^{-1}(c x)\right )^2}{e} \]

[Out]

-(((a + b*ArcTan[c*x])^2*Log[2/(1 - I*c*x)])/e) + ((a + b*ArcTan[c*x])^2*Log[(2*c*(d + e*x))/((c*d + I*e)*(1 -
 I*c*x))])/e + (I*b*(a + b*ArcTan[c*x])*PolyLog[2, 1 - 2/(1 - I*c*x)])/e - (I*b*(a + b*ArcTan[c*x])*PolyLog[2,
 1 - (2*c*(d + e*x))/((c*d + I*e)*(1 - I*c*x))])/e - (b^2*PolyLog[3, 1 - 2/(1 - I*c*x)])/(2*e) + (b^2*PolyLog[
3, 1 - (2*c*(d + e*x))/((c*d + I*e)*(1 - I*c*x))])/(2*e)

________________________________________________________________________________________

Rubi [A]  time = 0.0476133, antiderivative size = 223, normalized size of antiderivative = 1., number of steps used = 1, number of rules used = 1, integrand size = 18, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.056, Rules used = {4858} \[ -\frac{i b \left (a+b \tan ^{-1}(c x)\right ) \text{PolyLog}\left (2,1-\frac{2 c (d+e x)}{(1-i c x) (c d+i e)}\right )}{e}+\frac{i b \text{PolyLog}\left (2,1-\frac{2}{1-i c x}\right ) \left (a+b \tan ^{-1}(c x)\right )}{e}+\frac{b^2 \text{PolyLog}\left (3,1-\frac{2 c (d+e x)}{(1-i c x) (c d+i e)}\right )}{2 e}-\frac{b^2 \text{PolyLog}\left (3,1-\frac{2}{1-i c x}\right )}{2 e}+\frac{\left (a+b \tan ^{-1}(c x)\right )^2 \log \left (\frac{2 c (d+e x)}{(1-i c x) (c d+i e)}\right )}{e}-\frac{\log \left (\frac{2}{1-i c x}\right ) \left (a+b \tan ^{-1}(c x)\right )^2}{e} \]

Antiderivative was successfully verified.

[In]

Int[(a + b*ArcTan[c*x])^2/(d + e*x),x]

[Out]

-(((a + b*ArcTan[c*x])^2*Log[2/(1 - I*c*x)])/e) + ((a + b*ArcTan[c*x])^2*Log[(2*c*(d + e*x))/((c*d + I*e)*(1 -
 I*c*x))])/e + (I*b*(a + b*ArcTan[c*x])*PolyLog[2, 1 - 2/(1 - I*c*x)])/e - (I*b*(a + b*ArcTan[c*x])*PolyLog[2,
 1 - (2*c*(d + e*x))/((c*d + I*e)*(1 - I*c*x))])/e - (b^2*PolyLog[3, 1 - 2/(1 - I*c*x)])/(2*e) + (b^2*PolyLog[
3, 1 - (2*c*(d + e*x))/((c*d + I*e)*(1 - I*c*x))])/(2*e)

Rule 4858

Int[((a_.) + ArcTan[(c_.)*(x_)]*(b_.))^2/((d_) + (e_.)*(x_)), x_Symbol] :> -Simp[((a + b*ArcTan[c*x])^2*Log[2/
(1 - I*c*x)])/e, x] + (Simp[((a + b*ArcTan[c*x])^2*Log[(2*c*(d + e*x))/((c*d + I*e)*(1 - I*c*x))])/e, x] + Sim
p[(I*b*(a + b*ArcTan[c*x])*PolyLog[2, 1 - 2/(1 - I*c*x)])/e, x] - Simp[(I*b*(a + b*ArcTan[c*x])*PolyLog[2, 1 -
 (2*c*(d + e*x))/((c*d + I*e)*(1 - I*c*x))])/e, x] - Simp[(b^2*PolyLog[3, 1 - 2/(1 - I*c*x)])/(2*e), x] + Simp
[(b^2*PolyLog[3, 1 - (2*c*(d + e*x))/((c*d + I*e)*(1 - I*c*x))])/(2*e), x]) /; FreeQ[{a, b, c, d, e}, x] && Ne
Q[c^2*d^2 + e^2, 0]

Rubi steps

\begin{align*} \int \frac{\left (a+b \tan ^{-1}(c x)\right )^2}{d+e x} \, dx &=-\frac{\left (a+b \tan ^{-1}(c x)\right )^2 \log \left (\frac{2}{1-i c x}\right )}{e}+\frac{\left (a+b \tan ^{-1}(c x)\right )^2 \log \left (\frac{2 c (d+e x)}{(c d+i e) (1-i c x)}\right )}{e}+\frac{i b \left (a+b \tan ^{-1}(c x)\right ) \text{Li}_2\left (1-\frac{2}{1-i c x}\right )}{e}-\frac{i b \left (a+b \tan ^{-1}(c x)\right ) \text{Li}_2\left (1-\frac{2 c (d+e x)}{(c d+i e) (1-i c x)}\right )}{e}-\frac{b^2 \text{Li}_3\left (1-\frac{2}{1-i c x}\right )}{2 e}+\frac{b^2 \text{Li}_3\left (1-\frac{2 c (d+e x)}{(c d+i e) (1-i c x)}\right )}{2 e}\\ \end{align*}

Mathematica [F]  time = 0.154898, size = 0, normalized size = 0. \[ \int \frac{\left (a+b \tan ^{-1}(c x)\right )^2}{d+e x} \, dx \]

Verification is Not applicable to the result.

[In]

Integrate[(a + b*ArcTan[c*x])^2/(d + e*x),x]

[Out]

Integrate[(a + b*ArcTan[c*x])^2/(d + e*x), x]

________________________________________________________________________________________

Maple [C]  time = 0.26, size = 1297, normalized size = 5.8 \begin{align*} \text{result too large to display} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((a+b*arctan(c*x))^2/(e*x+d),x)

[Out]

a^2*ln(c*e*x+c*d)/e+b^2*ln(c*e*x+c*d)/e*arctan(c*x)^2-b^2/e*arctan(c*x)^2*ln(-I*(1+I*c*x)^2/(c^2*x^2+1)*e+c*d*
(1+I*c*x)^2/(c^2*x^2+1)+I*e+d*c)-I*a*b*ln(c*e*x+c*d)/e*ln((I*e+e*c*x)/(I*e-d*c))-1/2*I*b^2/e*arctan(c*x)^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)-I*a*b/e*dilog((I*e+e*c*x)/(I*
e-d*c))+1/2*I*b^2/e*arctan(c*x)^2*Pi*csgn(I/((1+I*c*x)^2/(c^2*x^2+1)+1))*csgn(I*(-I*(1+I*c*x)^2/(c^2*x^2+1)*e+
c*d*(1+I*c*x)^2/(c^2*x^2+1)+I*e+d*c)/((1+I*c*x)^2/(c^2*x^2+1)+1))*csgn(I*(-I*(1+I*c*x)^2/(c^2*x^2+1)*e+c*d*(1+
I*c*x)^2/(c^2*x^2+1)+I*e+d*c))+I*a*b/e*dilog((I*e-e*c*x)/(d*c+I*e))-I*b^2*arctan(c*x)*polylog(2,(I*e-d*c)/(d*c
+I*e)*(1+I*c*x)^2/(c^2*x^2+1))/(e+I*d*c)

________________________________________________________________________________________

Maxima [F]  time = 0., size = 0, normalized size = 0. \begin{align*} \frac{a^{2} \log \left (e x + d\right )}{e} + \int \frac{12 \, b^{2} \arctan \left (c x\right )^{2} + b^{2} \log \left (c^{2} x^{2} + 1\right )^{2} + 32 \, a b \arctan \left (c x\right )}{16 \,{\left (e x + d\right )}}\,{d x} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+b*arctan(c*x))^2/(e*x+d),x, algorithm="maxima")

[Out]

a^2*log(e*x + d)/e + integrate(1/16*(12*b^2*arctan(c*x)^2 + b^2*log(c^2*x^2 + 1)^2 + 32*a*b*arctan(c*x))/(e*x
+ d), x)

________________________________________________________________________________________

Fricas [F]  time = 0., size = 0, normalized size = 0. \begin{align*}{\rm integral}\left (\frac{b^{2} \arctan \left (c x\right )^{2} + 2 \, a b \arctan \left (c x\right ) + a^{2}}{e x + d}, x\right ) \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+b*arctan(c*x))^2/(e*x+d),x, algorithm="fricas")

[Out]

integral((b^2*arctan(c*x)^2 + 2*a*b*arctan(c*x) + a^2)/(e*x + d), x)

________________________________________________________________________________________

Sympy [F]  time = 0., size = 0, normalized size = 0. \begin{align*} \int \frac{\left (a + b \operatorname{atan}{\left (c x \right )}\right )^{2}}{d + e x}\, dx \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+b*atan(c*x))**2/(e*x+d),x)

[Out]

Integral((a + b*atan(c*x))**2/(d + e*x), x)

________________________________________________________________________________________

Giac [F]  time = 0., size = 0, normalized size = 0. \begin{align*} \int \frac{{\left (b \arctan \left (c x\right ) + a\right )}^{2}}{e x + d}\,{d x} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+b*arctan(c*x))^2/(e*x+d),x, algorithm="giac")

[Out]

integrate((b*arctan(c*x) + a)^2/(e*x + d), x)